package com.immunology.service.impl;

import java.util.Collection;
import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.immunology.dao.ComplaintDao;
import com.immunology.domain.Complaint;
import com.immunology.domain.Role;
import com.immunology.exception.DaoException;
import com.immunology.service.ComplaintService;

@Service
public class ComplaintServiceImpl implements ComplaintService{

	@Autowired
	private ComplaintDao complaintDao;
	
	@Override
	public Complaint findById(Long id) throws DaoException {
		return complaintDao.findById(id);
	}

	@Override
	public List<Complaint> getAll() throws DaoException {
		return complaintDao.getAll();
	}

	@Override
	public void saveOrUpdate(Collection<Complaint> entities)
			throws DaoException {
		complaintDao.saveOrUpdate(entities);
	}

	@Override
	public void saveOrUpdate(Complaint... entities) throws DaoException {
		complaintDao.saveOrUpdate(entities);
	}

	@Override
	public void update(Collection<Complaint> entities) throws DaoException {
		complaintDao.update(entities);
	}

	@Override
	public void update(Complaint... entities) throws DaoException {
		complaintDao.update(entities);
	}

	@Override
	public void delete(Collection<Complaint> entities) throws DaoException {
		complaintDao.delete(entities);
	}
	
	@Override
	public void delete(Complaint... entities) throws DaoException {
		complaintDao.delete(entities);
	}

	@Override
	public void deleteAll() throws DaoException {
		complaintDao.deleteAll();
	}

	@Override
	public void save(Collection<Complaint> entities) throws DaoException {
		complaintDao.save(entities);
	}

	@Override
	public void save(Complaint... entities) throws DaoException {
		complaintDao.save(entities);
	}

}
